package com.jingdong.service.shoppingCart;

import com.jingdong.dao.shoppingCart.ShoppingCartDao;
import com.jingdong.model.Shopping_cart;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class ShoppingCartServiceImpl implements ShoppingCartService {
    @Autowired
    private ShoppingCartDao shoppingCartDao;

    @Override
    public int save(Shopping_cart shopping_cart) {
        return shoppingCartDao.save(shopping_cart);
    }

    @Override
    public List<Shopping_cart> cartList(Map<String, Long> map) {
        return shoppingCartDao.cartList(map);
    }

    @Override
    public Shopping_cart getById(Map<String, Long> map) {
        return shoppingCartDao.getById(map);
    }

    @Override
    public int update(Shopping_cart shopping_cart) {
        return shoppingCartDao.update(shopping_cart);
    }
}
